package com.zhuhao.design_mode.behavioral_pattern.observer_pattern;

/**
 * 天气站台，将收集的数据，改变天气数据（被观察者），被观察者将通知观察者
 * @Author zhuhao
 * @Date 2022/5/29 21:15
 * @desc
 */
public class WeatherStationTest {

    public static void main(String[] args) {
        WeatherData weatherData = new WeatherData();
        StatisticsDisplay statisticsDisplay = new StatisticsDisplay(weatherData);
        CurrentConditionsDisplay currentConditionsDisplay = new CurrentConditionsDisplay(weatherData);

        weatherData.setMeasurements(25, 75, 1000);
        weatherData.setMeasurements(-10, 30, 1050);

    }
}
